package com.nulldev.util.graphics.renderIt.frontend;

/**
 * The frontend enum, used to select the frontend used for rendering components of the renderIt! API. <br>
 * 
 * 
 * @author null
 * @from nullUtil 2.7-earliest-alpha (part of "the GFX update!")
 */
public enum Frontend {
	/**
	 * Uses Java Swing + SmoothCanvas to perform medium/low graphically demanding tasks. <br>
	 * This is designed for unsupported operating systems. <br>
	 * Uses DirectX/OpenGL on selected operating systems. (via SwingUtil.enableJSO) <br>
	 * Threading: via threadIt! V3 (for handling recalls) <br>
	 * <b>THIS IS THE DEFAULT FALLBACK</b>
	 */
	Swing_Native("java.swing", "ExtendedSwing Renderer"),
	/**
	 * Uses SDL (Simple DirectMedia Layer) to perform high graphically demanding tasks. <br>
	 * Supported Operating Systems: <br>
	 * - Windows (Win32) <br>
	 * - Linux <br>
	 * This is only used if the OS is supported and SDL is installed. <br>
	 * SDL mode also supports rendering via OpenGL. (if GLEW is installed) <br>
	 * Threading: Single Threaded (for now) <br>
	 * <b>DEFAULT IF SUPPORTED</b> (unless REQUIRE_HIGH_PERFORMANCE is true)
	 */
	SDL_External("external.sdl", "SDL Renderer"),
	/**
	 * Uses the LWJGL (Lightweight Java Game Library) to perform very high graphically demanding tasks via OpenGL (2.0-4.x) <br>
	 * Supported Operating Systems: <br>
	 * - Windows <br>
	 * - Mac OS <br>
	 * - Linux <br>
	 * This is used if the operating system is supported and the graphics card can support OpenGL. <br>
	 * Threading: Single Threaded (One Thread per Context limit) <br>
	 * <b>THIS IS USED IF <i>REQUIRE_HIGH_PEFORMANCE</i> IS TRUE</b>
	 */
	LWJGL_External("external.lwjgl", "LWJGL Renderer")
	
	;
	
	private final String ID, displayName;
	
	private Frontend(final String frontendID, final String frontendDisplayName) {
		this.ID = frontendID;
		this.displayName = frontendDisplayName;
	}
}
